package so.sao.code.service.repository;

import java.util.List;

import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.stereotype.Repository;
import so.sao.code.service.domain.entity.RangeActivation;

@Repository
public interface RangeActivationDao extends JpaRepository<RangeActivation, Long> {

    List<RangeActivation> findByTagBatchIdAndStatus(long tagBatchId, int status);

    List<RangeActivation> findByStatusAndActivationMethodIn(int status, List<Integer> methods);

    List<RangeActivation> findByTagBatchId(Long tagBatchId);

    Long countByEseId(Long eseId);

    List<RangeActivation> findByTagBatchIdIn(List<Long> tagBatchIds);

	RangeActivation findById(long rangId);
  
	List<RangeActivation> findByProductIdAndTagBatchIdIn(Long productId,List<Long> ids);
}
